package IO流;

import java.io.FileWriter;
import java.io.IOException;

public class 字符输出流 {
    public static void main(String[] args) throws IOException {
        FileWriter fw = new FileWriter("C:\\Users\\gdq\\OneDrive\\桌面\\File文件夹\\777.txt");
        String str = "欢迎来到北京";
        fw.write(str);
        fw.write("你好我是小颗粒");
        fw.write("\r\n");
        fw.write("这是一封离别信");
        fw.close();
    }
}
